let systemInfo = uni.getSystemInfoSync(); //获取系统信息
let statusBar = systemInfo.statusBarHeight
//获取胶囊按钮到顶部的距离,单位px
let top = uni.getMenuButtonBoundingClientRect().top; //胶囊按钮的顶部
let height = uni.getMenuButtonBoundingClientRect().height; //胶囊按钮的高度
let gap = top - statusBar; //动态计算每台手机状态栏到胶囊按钮间距(单位rpx)
let capsuleHeight = 2 * gap + height //2*gap是为了让他转为px单位 //胶囊按钮到状态栏的高度
let navHeaderHeight = capsuleHeight + statusBar + 4 //我们要获取的高度信息(+4是为了导航条背景更丰满)
// console.log(statusBar);
// console.log(systemInfo);
// console.log(capsuleHeight);
// console.log(navHeaderHeight)
export {navHeaderHeight}
